﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using IRC.IRepairClouds.DataLayer;

namespace IRC.IRepairClouds.DataLayer {
    public sealed class DBConstSingleTon {
        private static volatile DBConstSingleTon instance;
        private static object syncRoot = new Object();

        private DBConstSingleTon() { }

        public static DBConstSingleTon Instance {
            get {
                if (instance == null) {
                    lock (syncRoot) {
                        if (instance == null)
                            instance = new DBConstSingleTon();
                    }
                }

                return instance;
            }
        }

    }

    public class PromotionSetup {
        public Dictionary<int, ProgramLocalProgramTimes> LocalProgramTimes { get; set; }
        public ProgramGlobalTimes GlobalTimes { get; set; }


    }

    public class ProgramLocalProgramTimes {
        public int EpopCheckCustomerTAT_FollowUpMail { get; set; }
        public int EpopCheckCustomerTAT_FirstFollowUpMail { get; set; }
        public int EpopCheckCustomerTAT_LastFollowUpMail { get; set; }
        public int? MaxPickUpAckTAT { get; set; }
        public int? MaxClearingTAT { get; set; }
    }

    public class ProgramGlobalTimes {
        public int PaymentMaxExecutionTAT { get; set; }
        public int PaymentGracePeriod { get; set; }
        public int FundingMaxSPInvoiceTAT { get; set; }
        public int FundingMaxHPPaymentTAT { get; set; }
        public int MaxPickUpAckTAT { get; set; }
        public int MaxClearingTAT { get; set; }
    }
}


